package com.nameless.controller;

import com.nameless.entity.Menu;
import com.nameless.service.MenuService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author keluoyisi
 * @program: tong-parent
 * @description:
 * @date 2023-02-23 20:38:00
 */
@RestController
@RequestMapping("/system/permission")
public class PermissionController {
    @Autowired
    private MenuService sysMenuService;
    @GetMapping("/selectPermission/{userId}")
    public List<Menu> selectPermission(@PathVariable Integer userId){
        return sysMenuService.selectPermission(userId);
    }
}